<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>vue求和</title>
		<script src="./js/vue.js">
			
		</script>
	</head>
	<body>
		<p id="app" style="text-align: center;">
		<input type="number" v-model="a" placeholder="a"/><br>
		<input type="number" v-model="b" placeholder="b"/><br>
		两数之和为:{{sum(a,b)}}
		</p>
		
		
		<!-- <button type="button" @click="show()">点我</button> -->
		<script>
			new Vue({
				el:"#app",
				data:{
					a:null,
					b:null
				},
				methods:{
					sum:function(a,b){
						return Number(a)*Number(b);
					}
				}
			})
		</script>
	</body>
</html>
